package test.struts.action;

import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;

import org.apache.struts.action.Action;
import org.apache.struts.action.ActionForm;
import org.apache.struts.action.ActionForward;
import org.apache.struts.action.ActionMapping;


public class IngresarLineaAction extends Action
{
    public ActionForward execute(ActionMapping mapping, ActionForm form, HttpServletRequest request, HttpServletResponse response)
    {
        String n = request.getParameter("linea");
        
        request.setAttribute("nombreIngresado",n);
        
        if( n.equals("DARIO") )
        	return mapping.findForward("toMostrarAplicacion");
        
        return mapping.findForward("toMostrarLineaIngresada");
    }    
}